package mysql

import "gorm.io/gorm"

type Typer struct {
	gorm.Model
	TyperName string `gorm:"type:varchar(30);comment:类别名"`
}

func (t *Typer) FindTyper(db *gorm.DB, name string) error {
	return db.Debug().Where("typers.typer_name=?", name).FirstOrCreate(t).Error
}
